www.gusucode.com > VC++ ASP文件上传组件源代码+调用示例-源码程序 > VC++ ASP文件上传组件源代码+调用示例-源码程序/code/asp_demo/ASPUploader Samples/Sample4b.asp
<%@ LANGUAGE=JScript%> <html> <head> <link href="style.css" rel=stylesheet type=text/css> <title>ASP Uploader Sample 4b</title> </head> <body> <h1>Sample 4b: Access form Data using index number</h1> <br> <table width=100% cellpadding=2><tr><td bgcolor="#000000"> <table width=100% bgcolor="#000000" cellpadding=4> <tr bgcolor=#bbeeff> <td align=center>Item Name</td> <td align=center>Count</td> <td align=center>Value</td> <td align=center>Subitems</td> </tr> <% var form = Server.CreateObject("MyRequest.Form"); form.Init(); var i; for(i = 1; i <= form.Count; i++) { %> <tr bgcolor=#ffffff> <td align=center style="font-size:60%"><%=form.Item(i).Name%></td> <td align=center style="font-size:60%"><%=form.Item(i).Count%></td> <td align=left style="font-size:60%; color:#338888"><%=form.Item(i).Value%></td> <td align=left style="font-size:60%; color:#ff0000"> <% var j; for(j = 1; j <= form.Item(i).Count; j++) { var item = form.Item(i).Item(j); if(item.isFile()) { Response.Write("<b>Item[" + j + "] =</b> Uploded File <br><b>File Name: </b> " + item.FileName + "<br><b>ContentType: </b> " + item.ContentType + "<br><b>TotalBytes: </b> " + item.TotalBytes +"<br>"); } else { Response.Write("<b>Item[" + j + "] =</b>" + item.Value + "<br>"); } } %> </td> </tr> <% } %> </table> </td></tr></table> <br> <div> Designed by Al-Mutairi, Fayez <br> e-mail: <a href="mailto:fayezmm@yahoo.com">fayezmm@yahoo.com</a><br> Copyright? 2001 </div> </body> </html>